import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [
  // 首页
  {
    path: '/',
    name: 'Home',
    component: () => import('@/views/home')
  },
  // 院部概况
  {
    path: '/overview',
    name: 'Overview',
    component: () => import('@/views/overview')
  },
  // 思政教育
  {
    path: '/education',
    name: 'Education',
    component: () => import('@/views/education')
  },
  // 学习天地
  {
    path: '/studysky',
    name: 'Studysky',
    component: () => import('@/views/studysky')
  },
  // 联系我们
  {
    path: '/callme',
    name: 'Callme',
    component: () => import('@/views/callme')
  },
  // 招生工作详情页1
  {
    path: '/tzgg',
    name: 'Tzgg',
    component: () => import('@/views/tzgg')
  },
  // 招生工作
  {
    path: '/admissions',
    name: 'Admissions',
    component: () => import('@/views/admissions')
  },
  //培养工作
  {
    path: '/nourish',
    name: 'Nourish',
    component: () => import('@/views/nourish')
  },
  // 招生工作详情页
  {
    path: '/zzgzxqy',
    name: 'Zzgzxqy',
    component: () => import('@/views/zzgzxqy')
  },
  // 留言板
  {
    path: '/lyb',
    name: 'lyb',
    component: () => import('@/views/lyb')
  },
  // 学科建设-1
  {
    path: '/xkjsone',
    name: 'xkjsone',
    component: () => import('@/views/xkjsone')
  },
  //学科建设
  {
    path: '/construction',
    name: 'Construction',
    component: () => import('@/views/construction')
  },
  //创新工作
  {
    path: '/innovation',
    name: 'Innovation',
    component: () => import('@/views/innovation')
  },
  // 登录
  {
    path: '/login',
    name: 'Login',
    component: () => import('@/views/login')
  },
  // 学科建设-教保条件
  {
    path: '/xkjsjbtj',
    name: 'xkjsjbtj',
    component: () => import('@/views/xkjsjbtj')
  },
  // 个人中心
  {
    path: '/personal',
    name: 'Personal',
    redirect: '/core',
    component: () => import('@/views/personal/index.vue'),
    children: [
      // 个人中心
      {
        path: '/core',
        name: 'Core',
        component: () => import('@/views/personal/core.vue')
      },
      //消息中心
      {
        path: '/news',
        name: 'News',
        component: () => import('@/views/personal/news.vue')
      },
      //互动交流
      {
        path: '/interactive',
        name: 'Interactive',
        component: () => import('@/views/personal/interactive.vue')
      },
      //咨询答疑
      {
        path: '/consult',
        name: 'Consult',
        component: () => import('@/views/personal/consult.vue')
      },
      //网站邮箱
      {
        path: '/mail',
        name: 'Mail',
        component: () => import('@/views/personal/mail.vue')
      },
    ]
  },

]


const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
